
<style>
    #contributions-table tbody td {
        cursor: pointer;
    }

    #contributions-table tbody tr.selected td {
        background-color: #38b6d0 !important;
        color: #fff;
    }

    #contributions-table tbody tr.selected td .text-muted {
        color: #eee;
    }
</style>

<div class="" id="container">

    <div class="row">

        <div class="col-lg-4">
            <div class="panel">
                <div class="panel-heading">
                    <div class="row">
                        <div class="col-lg-5">Contribution Types</div>

                        <div class="col-lg-7 text-right">
                            <button href='<?php echo $this->Html->url(array('action' => 'contribution_types', 'add_edit')); ?>' id='add_btn' title="Add" class="btn btn-sm btn-info">
                                <i class="fa fa-plus"></i>
                                Add New
                            </button>

                            <button href='<?php echo $this->Html->url(array('action' => 'contribution_types', 'delete')); ?>' id='del_btn' title="Remove" class="btn btn-sm btn-danger">
                                <i class="fa fa-minus"></i>

                                Delete
                            </button>
                        </div>
                    </div>
                </div>

                <div class="panel-body no-padder">
                    <table id="contributions-table" class="table table-striped table-hover">
                        <thead>
                        <tr>
                            <th width="30">
                                <input type="checkbox" />
                            </th>
                            <th>Name</th>
                        </tr>
                        </thead>

                        <tbody>
                        <?php
                        foreach ($list as $item) {
                            ?>
                            <tr>
                                <td>
                                    <input type="checkbox" value="<?php echo $item['id']; ?>" />
                                </td>
                                <td class="info" data-id="<?php echo $item['id']; ?>">
                                    <?php echo $item['name']; ?>
                                </td>
                            </tr>
                        <?php
                        }
                        ?>
                        </tbody>

                    </table>
                </div>
            </div>
        </div>


        <div class="col-lg-8">
            <div class="panel m-b-none" id="contributions_view">
                <div class='panel-heading'>
                    <div class='row'>
                        <div class='col-lg-9'>

                        </div>
                        <div class='col-lg-3'>
                            <button id='edit_btn' class='btn btn-sm btn-info pull-right'>
                                <i class='fa fa-pencil'></i>

                                Edit
                            </button>
                        </div>
                    </div>
                </div>
                <div class="panel-body m-b-none">

                </div>
            </div>
        </div>
    </div>
</div>

<input type="hidden" id="contribution_types_url" value="<?php echo $this->Html->url(array('action' => 'contribution_types')); ?>" />

<?php
/*echo $this->Html->script('plugins/jquery.trocar/jquery.trocar.js');
echo $this->Html->script('plugins/jquery.friendurl/jquery.friendurl.min.js');*/
echo $this->Html->script('app/views/organisations/contribution_types.js');
?>